import 'package:flutterproject/generated/json/base/json_convert_content.dart';
import 'package:flutterproject/page/mine/children/assets/data/zengzhi_bean.dart';

ZengzhiBean $ZengzhiBeanFromJson(Map<String, dynamic> json) {
	final ZengzhiBean zengzhiBean = ZengzhiBean();
	final double? balance = jsonConvert.convert<double>(json['balance']);
	if (balance != null) {
		zengzhiBean.balance = balance;
	}
	final List<ZengzhiList>? list = jsonConvert.convertListNotNull<ZengzhiList>(json['list']);
	if (list != null) {
		zengzhiBean.list = list;
	}
	return zengzhiBean;
}

Map<String, dynamic> $ZengzhiBeanToJson(ZengzhiBean entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['balance'] = entity.balance;
	data['list'] =  entity.list?.map((v) => v.toJson()).toList();
	return data;
}

ZengzhiList $ZengzhiListFromJson(Map<String, dynamic> json) {
	final ZengzhiList zengzhiList = ZengzhiList();
	final int? id = jsonConvert.convert<int>(json['id']);
	if (id != null) {
		zengzhiList.id = id;
	}
	final int? createTime = jsonConvert.convert<int>(json['createTime']);
	if (createTime != null) {
		zengzhiList.createTime = createTime;
	}
	final int? updateTime = jsonConvert.convert<int>(json['updateTime']);
	if (updateTime != null) {
		zengzhiList.updateTime = updateTime;
	}
	final int? flag = jsonConvert.convert<int>(json['flag']);
	if (flag != null) {
		zengzhiList.flag = flag;
	}
	final int? type = jsonConvert.convert<int>(json['type']);
	if (type != null) {
		zengzhiList.type = type;
	}
	final String? title = jsonConvert.convert<String>(json['title']);
	if (title != null) {
		zengzhiList.title = title;
	}
	final double? type2Rate = jsonConvert.convert<double>(json['type2Rate']);
	if (type2Rate != null) {
		zengzhiList.type2Rate = type2Rate;
	}
	final int? type2Term = jsonConvert.convert<int>(json['type2Term']);
	if (type2Term != null) {
		zengzhiList.type2Term = type2Term;
	}
	return zengzhiList;
}

Map<String, dynamic> $ZengzhiListToJson(ZengzhiList entity) {
	final Map<String, dynamic> data = <String, dynamic>{};
	data['id'] = entity.id;
	data['createTime'] = entity.createTime;
	data['updateTime'] = entity.updateTime;
	data['flag'] = entity.flag;
	data['type'] = entity.type;
	data['title'] = entity.title;
	data['type2Rate'] = entity.type2Rate;
	data['type2Term'] = entity.type2Term;
	return data;
}